import request from '@/utils/request'

// 查询文件分享列表
export function listShare(query) {
  return request({
    url: '/share/share/list',
    method: 'get',
    params: query
  })
}

// 查询文件分享详细
export function getShare(shareId) {
  return request({
    url: '/share/share/' + shareId,
    method: 'get'
  })
}

// 新增文件分享
export function addShare(data) {
  return request({
    url: '/share/share',
    method: 'post',
    data: data
  })
}

// 修改文件分享
export function updateShare(data) {
  return request({
    url: '/share/share',
    method: 'put',
    data: data
  })
}

// 删除文件分享
export function delShare(shareId) {
  return request({
    url: '/share/share/' + shareId,
    method: 'delete'
  })
}
